﻿#include <gtest/gtest.h>

#include <CommonUnits/BasicFixedString.h>

TEST(BasicFixedString, BasicFixedString)
{
    constexpr CU::BasicFixedString kv("kV");
    constexpr CU::BasicFixedString ohm("Ω");
    EXPECT_EQ(CU::BasicFixedString("kV"), kv);
    EXPECT_FALSE(CU::BasicFixedString("V") > kv);
    EXPECT_EQ(CU::BasicFixedString("kV"), kv);
    auto str = static_cast<std::string>(CU::BasicFixedString("V"));
    EXPECT_EQ(str, CU::BasicFixedString("V").c_str());
}

int main(int argc, char* argv[])
{
    testing::InitGoogleTest(&argc, argv);
    return RUN_ALL_TESTS();
}
